﻿@if (User.Identity.IsAuthenticated)
{
    <ul class="nav navbar-nav navbar-right">
        <li>
            <a href="#" title="管理">你好，@*@(Session["UserName"].User.Identity.Name)!*@</a>
        </li>
        <li><a href="@Url.Action("Logout", "Account")">注销</a></li>
    </ul>
}
else
{
    <ul class="nav navbar-nav navbar-right">
        <li>@Html.ActionLink("登录", "Login", "Account", routeValues: null, htmlAttributes: new { id = "loginLink" })</li>
    </ul>
}